use macros::base_model;
use sea_orm::entity::prelude::*;
use serde::{Deserialize, Serialize};

#[base_model]
#[derive(Clone, Debug, PartialEq, Eq, DeriveEntityModel, Serialize, Deserialize)]
#[sea_orm(table_name = "project", comment = "系统配置表")]
pub struct Model {

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_system: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub project_mng: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub reg_code: Option<String>,

    #[sea_orm(column_type = "Integer", nullable)]
    pub g_level: Option<i32>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_code: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub industry: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub category: Option<String>,

    #[sea_orm(column_type = "Text", not_null)]
    pub creator_id: String,

    #[sea_orm(column_type = "Text", nullable)]
    pub uuid: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_name: Option<String>,

    #[sea_orm(column_type = "Integer", nullable)]
    pub year: Option<i32>,

    #[sea_orm(column_type = "Integer", nullable)]
    pub batch: Option<i32>,

    #[sea_orm(column_type = "Integer", nullable)]
    pub s_level: Option<i32>,

    #[sea_orm(column_type = "Integer", nullable)]
    pub a_level: Option<i32>,

    #[sea_orm(column_type = "Text", nullable)]
    pub topology_img: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub topology_description: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub reg_img: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_org: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub system_des: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_addr: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_postcode: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_contact: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_position: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_department: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_phone: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_mobile: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_email: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_addr: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_postcode: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_contact: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_position: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_department: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_phone: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_mobile: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub org_email: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub business_technologies: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub point: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub entry_point: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub point_img: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub penetration_img: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub process_ready: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub process_plan: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub process_do: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub process_write: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_boss: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_type: Option<String>,

    #[sea_orm(column_type = "Text", nullable)]
    pub eval_des: Option<String>,

    #[sea_orm(column_type = "Text", not_null)]
    pub creator_name: String,
}

#[derive(Copy, Clone, Debug, EnumIter, DeriveRelation)]
pub enum Relation {}
